const xss = require('node-xss').clean;

const xxs = (req, res) => {
    console.log(req);
    //对请求体做xss过滤
    var data = xss(req.body);
    var url = urlMap.englishlistenspeakserver + '/orders/insert-orders';
    var options = {
        url: url,
        method: 'POST',
        json: true,
        qs: data
    };
    request(options, function (error, response, body) {
        res.send(body);
    })
    console.log('data:',data);
    console.log('url:',url);
    console.log('options:',options);
}

module.exports = {xxs}